<div class="admin_left actions">
    <h3 style="font-size:20px;">Manage more</h3>
	<ul>
		<li style="list-style-type:none; margin-bottom:20%;"><?php echo $this->Html->link(__('Edit Condition'), array('action' => 'edit', $condition['Condition']['id']),array('class' => 'consistentButton')); ?> </li>
		<li style="list-style-type:none; margin-bottom:20%;"><?php echo $this->Form->postLink(__('Delete Condition'), array('action' => 'delete', $condition['Condition']['id']),array('class' => 'consistentButton'), null, __('Are you sure you want to delete # %s?', $condition['Condition']['id'])); ?> </li>
		<li style="list-style-type:none; margin-bottom:20%;"><?php echo $this->Html->link(__('List Conditions'), array('action' => 'index'),array('class' => 'consistentButton')); ?> </li>
		<li style="list-style-type:none; margin-bottom:20%;"><?php echo $this->Html->link(__('New Condition'), array('action' => 'add'),array('class' => 'consistentButton')); ?> </li>
		<li style="list-style-type:none; margin-bottom:20%;"><?php echo $this->Html->link(__('List Items'), array('controller' => 'items', 'action' => 'index'),array('class' => 'consistentButton')); ?> </li>
		<li style="list-style-type:none; margin-bottom:20%;"><?php echo $this->Html->link(__('New Item'), array('controller' => 'items', 'action' => 'add'),array('class' => 'consistentButton')); ?> </li>
	</ul>
</div>

<div class="admin_right conditions view">

<div id=breadcrumbAdmin>
    <?php $this->Html->addCrumb('Conditions', '/Conditions/index'); ?>
    <?php $this->Html->addCrumb('View', '/Conditions/view', array('style'=> ('text-decoration:underline; color:#EB1E70;'))); ?>
    <?php echo $this->Html->getCrumbs(' > ', array( 'text' => 'Items', 'url' => array('controller' => 'items', 'action' => 'index'), 'escape' => false)); ?>
</div>

    <h2><?php  echo __('Condition'); ?></h2>
	<table class="table table-striped table-bordered">
        <tr>
            <th><?php echo __('Id'); ?></th>
            <th><?php echo __('Name'); ?></th>
        </tr>
        <tr>

            <td>
                <?php echo h($condition['Condition']['id']); ?>
                &nbsp;
            </td>

            <td>
                <?php echo h($condition['Condition']['name']); ?>
                &nbsp;
            </td>
        </tr>
	</table>

    <?php if ($current_customer['group_id'] == 1): ?>

    <?php endif; ?>


    <div style="border-top:solid 1px; margin-top:10%;" class="related">
        <h4><?php echo __('Related Items'); ?></h4>
        <?php if (!empty($condition['Item'])): ?>
            <table cellpadding = "0" cellspacing = "0"class="table table-striped table-bordered">
                <tr>
                    <th><?php echo __('Id'); ?></th>
                    <th><?php echo __('Name'); ?></th>
                    <th><?php echo __('Brand Id'); ?></th>
                    <th><?php echo __('Color Id'); ?></th>
                    <th><?php echo __('Condition Id'); ?></th>
                    <th><?php echo __('Size Id'); ?></th>
                    <th><?php echo __('Category Id'); ?></th>
                    <th><?php echo __('Item Status Id'); ?></th>
                    <th><?php echo __('Original Price'); ?></th>
                    <th class="actions"><?php echo __('Actions'); ?></th>
                </tr>
                <?php $i = 0; foreach ($condition['Item'] as $item): ?>
                    <tr>
                        <td><?php echo $item['id']; ?></td>
                        <td><?php echo $item['name']; ?></td>
                        <td><?php echo $item['brand_id']; ?></td>
                        <td><?php echo $item['color_id']; ?></td>
                        <td><?php echo $item['condition_id']; ?></td>
                        <td><?php echo $item['size_id']; ?></td>
                        <td><?php echo $item['category_id']; ?></td>
                        <td><?php echo $item['item_status_id']; ?></td>
                        <td><?php echo $item['original_price']; ?></td>
                        <td class="actions">
                            <?php echo $this->Html->link(__('Edit'), array('controller' => 'items', 'action' => 'edit', $item['id'])); ?>
                            <?php echo $this->Form->postLink(__('Delete'), array('controller' => 'items', 'action' => 'delete', $item['id']), null, __('Are you sure you want to delete # %s?', $item['id'])); ?>
                        </td>
                    </tr>
                <?php endforeach; ?>
            </table>
        <?php endif; ?>
        <?php if ($current_customer['group_id'] == 1): ?>
            <div  style="margin-left:78%;" class="actions">
                <ul>
                    <li style="list-style-type:none; margin-left:0; padding-top:15px;"><?php echo $this->Html->link(__('Add item to this condition'), array('controller' => 'items', 'action' => 'add')); ?> </li>
                </ul>
            </div>
        <?php endif; ?>
    </div>
</div>

